<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 
<html xml:lang="fr" lang="fr" xmlns="http://www.w3.org/1999/xhtml"> 
<head> 
 <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> 
 <title></title> 
 <link rel="stylesheet" type="text/css" href="stylesheet_appli.css" /> 
<script type="text/javascript"> 
  
var c,c2,ch,num,start; 
start = 11; 
  
// ajouter un champ avec son "name" propre; 
function plus(){ 
c=document.getElementById('div'); 
c2=c.getElementsByTagName('input'); 
num=c2.length + start; 

document.getElementById('div').innerHTML = '<td>'; 

ch=document.createElement('input'); 
ch.setAttribute('type','text'); 
ch.setAttribute('name','ref'+num); 
c.appendChild(ch); 

document.getElementById('div').innerHTML = '</td><td>'; 

ch=document.createElement('input'); 
ch.setAttribute('type','text'); 
ch.setAttribute('name','desc'+num); 
c.appendChild(ch); 

document.getElementById('div').innerHTML = '</td><td>'; 

ch=document.createElement('input'); 
ch.setAttribute('type','text'); 
ch.setAttribute('name','qte'+num); 
c.appendChild(ch); 

document.getElementById('div').innerHTML = '</td><td>'; 

ch=document.createElement('input'); 
ch.setAttribute('type','radio'); 
ch.setAttribute('name','type'+num); 
c.appendChild(ch); 

ch=document.createElement('input'); 
ch.setAttribute('type','radio'); 
ch.setAttribute('name','type'+num); 
c.appendChild(ch); 

document.getElementById('div').innerHTML = '</td><td>'; 

ch=document.createElement('input'); 
ch.setAttribute('type','text'); 
ch.setAttribute('name','obs'+num); 
c.appendChild(ch); 

document.getElementById('div').innerHTML = '</td>'; 

// document.getElementById('sup').style.display='inline'; 
}  
</script> 
</head> 
<body id='body' > 
<form id='form' method='post' action='demandeFournitureEffectuee.php'> 
<div id='div'> 
</div> 
<table id='demande'> 
<tr> 
 <td></td> 
 <th>Référence</th> 
 <th>Description*</th> 
 <th>Quantité*</th> 
 <th>Type*</th> 
 <th>Observations éventuelles</th> 
</tr> 


</table> 
<p class='petit'>* Champ obligatoire</p> 
<br /> 
<div class='center'> 
<input type="button" value="Ajouter une ligne" onclick="plus()" /> 
<input type='submit' value='Valider' class='submit' /> 
</form> 
<form action='index.php' class='right'> 
 <input type='submit' value='Retour' class='submit' /> 
</form> 
</div> 
</body> 
</html>